In drilling wells for oil and gas exploration, understanding the structure and properties of the associated geological formation provides information to aid such exploration. Measurements in a borehole are typically performed to attain this understanding. Measurements can be made by tools conveyed into the regions of interest within a casing, but with tools activated when not in the casing. It is important to be able to determine whether tools are in casing. This determination may be especially significant for nuclear magnetic resonance tools. Firing in casing not only wastes energy, but can also short a tool's antenna or other components, or other measuring device, and potentially damage the hardware. Firing in casing can also produce false logs. For example, if casing is not detected when a tool is in a large diameter riser pipe section, the tool may not be overstressed in operation, but may produce a false log. Therefore, casing detection can be valuable for logging tools. In some standard approaches, only resonant frequency calculated by the gain amplitude maximum would be used to detect casing. The usefulness of such measurements may be related to the precision or quality of the process of making measurements for casing detection.